
 
 F u n c t i o n :   q u e r y D C ( a r r a y O f I d s ,   f u n c t i o n F i l t e r C a l l b a c k ( D C ) ) 
 
 
 
 D e s c r i p t i o n :   S e a r c h e s   t h r o u g h   a l l   r e g i s t e r e d   D C   o b j e c t s   a n d   p e r f o r m s   a   c a l l b a c k   f u n c t i o n   o n   e a c h   m a t c h   t o   f i l t e r   t h e   r e t u r n e d   a r r a y . 
 
 
 
 R e t u r n s :   D C   O b j e c t   A r r a y . 
 
 
 
 N o t e :   W h e n   a r r a y O f I d s   i s   s p e c i f i e d ,   t h e   l o o p   a c t i o n   w i l l   o n l y   s e a r c h   t h r o u g h   t h e   D C   o b j e c t s   t h a t   a r e   b o u n d   t o   t h e   i d s   w i t h i n   t h a t   a r r a y .   O t h e r w i s e ,   a l l   r e g i s t e r e d   D C   o b j e c t s   w i l l   b e   s e a r c h e d   a n d   t h e   f i l t e r   f u n c t i o n   w i l l   b e   a p p l i e d   t o   e a c h .   T o   p r e v e n t   a   D C   o b j e c t   f r o m   b e i n g   a d d e d   t o   t h e   r e t u r n e d   a r r a y ,   r e t u r n   f a l s e   m u s t   b e   a d d e d   t o   t h e   f i l t e r   c a l l b a c k   f u n c t i o n .   T h e   q u e r y D C ( )   f u n c t i o n   d o e s   n o t   s u p p o r t   c h a i n i n g . 
 
 
 
 E x a m p l e : 
 
 
 
 / /   P e r f o r m   a   c a l l b a c k   o n   e a c h   r e g i s t e r e d   D C   o b j e c t . 
 
 $ A . q u e r y D C ( f u n c t i o n ( D C )   { 
 
     / /   D o   s o m e t h i n g   w i t h   D C 
 
 } ) ; 
 
 
 
 / /   S e a r c h   t h r o u g h   a l l   r e g i s t e r e d   D C   o b j e c t s   t h a t   a r e   b o u n d   t o   t h e   i d s   s p e c i f i e d   i n   t h e   f i r s t   p a r a m e t e r   a n d   p e r f o r m   a   c a l l b a c k   o n   e a c h   m a t c h i n g   D C   o b j e c t . 
 
 $ A . q u e r y D C ( [ 
 
     " i d 1 " ,   " i d 2 " ,   " i d 3 " 
 
 ] ,   f u n c t i o n ( D C )   { 
 
     / /   D o   s o m e t h i n g   w i t h   D C 
 
 } ) ; 
 
 
 
 / /   S e a r c h   t h r o u g h   a l l   r e g i s t e r e d   D C   o b j e c t s   a n d   r e t u r n   a n   a r r a y   t h a t   m a t c h e s   t h e   f i l t e r   d i r e c t i v e . 
 
 v a r   m y D i a l o g s   =   $ A . q u e r y D C ( f u n c t i o n ( D C )   { 
 
     r e t u r n   ( d c . w i d g e t T y p e   = = =   " D i a l o g " ) ; 
 
 } ) ; 
 
 